package com.shuyuansystem.controller;

import com.shuyuansystem.entity.Result;
import com.shuyuansystem.service.OssUploadService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

@RestController
public class UploadController
{
    @Autowired
    private OssUploadService ossUploadService;

    @PostMapping("/upload")
    public Result uploadImg(MultipartFile img)
    {

        return ossUploadService.uploadImge(img);
    }
}